import VueRouter from 'vue-router'

// 导入对应的路由组件
import jobContainer from './components/tabbar/jobContainer.vue'
import companyContainer from './components/tabbar/companyContainer.vue'
import newsContainer from './components/tabbar/newsContainer.vue'
import myContainer from './components/tabbar/myContainer.vue'
import pickcity from './components/job/pickcity.vue'
import pickwork from './components/job/pickwork.vue'
// import joblist from './components/job/joblist.vue'



// 3. 创建路由对象
var router = new VueRouter({
  routes: [ // 配置路由规则
    { path: '/', redirect: '/job' },
    {
      path: '/job',
      name: 'job',
      component: jobContainer,
      children: [
        {
          path: 'pickcity',
          name: 'pickcity',
          component: pickcity
        },
        {
          path: 'pickwork',
          name: 'pickwork',
          component: pickwork
        },
        

      ]
    },
    { path: '/company', component: companyContainer },
    { path: '/news', component: newsContainer },
    { path: '/my', component: myContainer },

  ],
})

export default router